<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<!--[if lt IE 9]>
<script type="text/javascript" src="lib/html5.js"></script>
<script type="text/javascript" src="lib/respond.min.js"></script>
<script type="text/javascript" src="lib/PIE_IE678.js"></script>
<![endif]-->
<link href="css/H-ui.min.css" rel="stylesheet" type="text/css" />
<link href="css/H-ui.admin.css" rel="stylesheet" type="text/css" />
<link href="lib/Hui-iconfont/1.0.7/iconfont.css" rel="stylesheet" type="text/css" />
<link href="lib/webuploader/0.1.5/webuploader.css" rel="stylesheet" type="text/css" />
<link href="css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="lib/jquery/1.9.1/jquery.min.js"></script> 
<!--[if IE 6]>
<script type="text/javascript" src="lib/DD_belatedPNG_0.0.8a-min.js" ></script>
<script>DD_belatedPNG.fix('*');</script>
<![endif]-->

<title>头像批量上传</title>
</head>
<body>
<div class="pd-20">
	<form action="" method="post" class="form form-horizontal" id="form1">
		
		

		
		
		


		

		<div class="row cl">
			<label class="form-label col-2">上传头像：</label>
			<div class="formControls col-10" >
				
				<span class="l mb-10 fujian" id="fujian">
					<!-- <li><img src="/Upload/article/4/5721763bd1d88.jpg"><i class="Hui-iconfont" onclick="fj_close(this);">&#xe706;</i></li> -->
				</span>
				<i class="Hui-iconfont fujianadd"  onclick="_open('添加附件','article-imageupload.html?type=image&idname=fujian&api=user&single=0&inputname=avatar','750px','470px',true)">&#xe610;</i>


			</div>
		</div>

		
		
		
		
		<!-- <div class="row cl">
			<label class="form-label col-2">上传头像：</label>
			<div class="formControls col-10" >
				
				<span class="l mb-10 fujian" id="fujian">
					
				</span>
				<i class="Hui-iconfont fujianadd" onclick="_open('添加附件','article-imageupload.html?type=image&idname=fujian&api=user&single=0&inputname=avatar','750px','470px',true)">&#xe610;</i>


				
	
				
	
			</div>
		</div> -->
		
		
		

		
</div>

<div class="row cl pr-20" style="position:fixed; bottom:10px; width: 200px; right: 10px; text-align: right; z-index:1000; ">
	
		<button class="btn btn-primary radius" type="submit"><i class="Hui-iconfont">&#xe632;</i> 保存</button>
		<button onClick="removeIframe();" class="btn btn-default radius" type="button" style="margin-left:10px;">&nbsp;&nbsp;取消&nbsp;&nbsp;</button>
	
</div>
</form>

<script type="text/javascript" src="lib/layer/2.1/layer.js"></script> 

<script type="text/javascript" src="lib/Validform/5.3.2/Validform.min.js"></script> 
<script type="text/javascript" src="lib/webuploader/0.1.5/webuploader.min.js"></script> 
<script type="text/javascript" src="lib/ueditor/1.4.3/ueditor.config.js"></script> 
<script type="text/javascript" src="lib/ueditor/1.4.3/ueditor.all.min.js"> </script> 
<script type="text/javascript" src="lib/ueditor/1.4.3/lang/zh-cn/zh-cn.js"></script> 
<script type="text/javascript" src="js/H-ui.js"></script> 
<script type="text/javascript" src="js/H-ui.admin.js"></script> 
<script type="text/javascript" src="js/template-native.js"></script> 
<script type="text/javascript" src="js/s.js"></script> 

<script type="text/javascript" src="lib/daterangepicker/moment.min.js"></script> 
<script type="text/javascript" src="lib/daterangepicker/jquery.daterangepicker.js"></script>
<link rel="stylesheet" href="lib/daterangepicker/daterangepicker.css" /> 


<script type="text/javascript">
var gc_id1,gc_id2;//分类
var service=[];



function removeIframe(){
	var index = parent.layer.getFrameIndex(window.name);
    parent.layer.close(index);
}




$(function(){






	$("#form1").attr("action", API_AVATAR); 

	var editid=getUrlParam('editid');//编辑菜单id



	if(editid!==null){	     
	    var eidturl=API_AVATAR+"?id="+editid;
	    // 读取即将编辑的文章信息
	    $.getJSON(eidturl,function(data){

	    	if(!checkStatus(data)) return;//判断登录

	    	if(data.datas==''){
	    		layer.msg("数据加载错误", {icon:2,time:1000});
	    	}else{

	            

	            
	            var goods_images=data.datas.goods_images;
	        	for (x in goods_images){
	        		$('#fujian').show();
	        		$('#fujian').append('<li><img src="'+getIcon(goods_images[x])+'"><i class="Hui-iconfont" onclick="fj_close(this);">&#xe706;</i><input type="hidden" name="goods_images2['+x+']" value="'+goods_images[x]+'"></li>');
	        	   	// $('#fujian').append('<li><img src="'+getIcon(goods_images[x])+'"><i class="Hui-iconfont" onclick="fj_close(this);">&#xe706;</i><input type="hidden" name="goods_images2['+x+']" value="'+goods_images[x]+'"></li>');	
	        	}


	        	      //       var goods_images=data.datas.images;
	        		     //    $('#fujian').html("");
	        		    	// for (x in goods_images){

	        		    	// 	$('#fujian').show();
	        		    	//    	$('#fujian').append('<li><img src="'+getIcon(goods_images[x])+'"><i class="Hui-iconfont" onclick="fj_close(this);">&#xe706;</i><input type="hidden" name="goods_images2['+x+']" value="'+goods_images[x]+'"></li>');	
	        		    	// } 
	            

	            

	 
	        }
	    })
	}




	Validformsubmit("#form1");

	
	
	



});


// 移除选中的图片
function fj_close(obj){
	$(obj).parents("li").remove();
}


</script>
</body>
</html>